package com.uek.pojo;

import java.util.ArrayList;
import java.util.Date;
import java.util.Iterator;
import java.util.List;

public class SaleVisitExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public SaleVisitExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        protected void addCriterionForJDBCDate(String condition, Date value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            addCriterion(condition, new java.sql.Date(value.getTime()), property);
        }

        protected void addCriterionForJDBCDate(String condition, List<Date> values, String property) {
            if (values == null || values.size() == 0) {
                throw new RuntimeException("Value list for " + property + " cannot be null or empty");
            }
            List<java.sql.Date> dateList = new ArrayList<java.sql.Date>();
            Iterator<Date> iter = values.iterator();
            while (iter.hasNext()) {
                dateList.add(new java.sql.Date(iter.next().getTime()));
            }
            addCriterion(condition, dateList, property);
        }

        protected void addCriterionForJDBCDate(String condition, Date value1, Date value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            addCriterion(condition, new java.sql.Date(value1.getTime()), new java.sql.Date(value2.getTime()), property);
        }

        public Criteria andVistitIdIsNull() {
            addCriterion("vistit_id is null");
            return (Criteria) this;
        }

        public Criteria andVistitIdIsNotNull() {
            addCriterion("vistit_id is not null");
            return (Criteria) this;
        }

        public Criteria andVistitIdEqualTo(Integer value) {
            addCriterion("vistit_id =", value, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitIdNotEqualTo(Integer value) {
            addCriterion("vistit_id <>", value, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitIdGreaterThan(Integer value) {
            addCriterion("vistit_id >", value, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("vistit_id >=", value, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitIdLessThan(Integer value) {
            addCriterion("vistit_id <", value, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitIdLessThanOrEqualTo(Integer value) {
            addCriterion("vistit_id <=", value, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitIdIn(List<Integer> values) {
            addCriterion("vistit_id in", values, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitIdNotIn(List<Integer> values) {
            addCriterion("vistit_id not in", values, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitIdBetween(Integer value1, Integer value2) {
            addCriterion("vistit_id between", value1, value2, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitIdNotBetween(Integer value1, Integer value2) {
            addCriterion("vistit_id not between", value1, value2, "vistitId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdIsNull() {
            addCriterion("vistit_cust_id is null");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdIsNotNull() {
            addCriterion("vistit_cust_id is not null");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdEqualTo(Long value) {
            addCriterion("vistit_cust_id =", value, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdNotEqualTo(Long value) {
            addCriterion("vistit_cust_id <>", value, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdGreaterThan(Long value) {
            addCriterion("vistit_cust_id >", value, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdGreaterThanOrEqualTo(Long value) {
            addCriterion("vistit_cust_id >=", value, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdLessThan(Long value) {
            addCriterion("vistit_cust_id <", value, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdLessThanOrEqualTo(Long value) {
            addCriterion("vistit_cust_id <=", value, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdIn(List<Long> values) {
            addCriterion("vistit_cust_id in", values, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdNotIn(List<Long> values) {
            addCriterion("vistit_cust_id not in", values, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdBetween(Long value1, Long value2) {
            addCriterion("vistit_cust_id between", value1, value2, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitCustIdNotBetween(Long value1, Long value2) {
            addCriterion("vistit_cust_id not between", value1, value2, "vistitCustId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdIsNull() {
            addCriterion("vistit_user_id is null");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdIsNotNull() {
            addCriterion("vistit_user_id is not null");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdEqualTo(Long value) {
            addCriterion("vistit_user_id =", value, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdNotEqualTo(Long value) {
            addCriterion("vistit_user_id <>", value, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdGreaterThan(Long value) {
            addCriterion("vistit_user_id >", value, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdGreaterThanOrEqualTo(Long value) {
            addCriterion("vistit_user_id >=", value, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdLessThan(Long value) {
            addCriterion("vistit_user_id <", value, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdLessThanOrEqualTo(Long value) {
            addCriterion("vistit_user_id <=", value, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdIn(List<Long> values) {
            addCriterion("vistit_user_id in", values, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdNotIn(List<Long> values) {
            addCriterion("vistit_user_id not in", values, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdBetween(Long value1, Long value2) {
            addCriterion("vistit_user_id between", value1, value2, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitUserIdNotBetween(Long value1, Long value2) {
            addCriterion("vistit_user_id not between", value1, value2, "vistitUserId");
            return (Criteria) this;
        }

        public Criteria andVistitTimeIsNull() {
            addCriterion("vistit_time is null");
            return (Criteria) this;
        }

        public Criteria andVistitTimeIsNotNull() {
            addCriterion("vistit_time is not null");
            return (Criteria) this;
        }

        public Criteria andVistitTimeEqualTo(Date value) {
            addCriterionForJDBCDate("vistit_time =", value, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitTimeNotEqualTo(Date value) {
            addCriterionForJDBCDate("vistit_time <>", value, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitTimeGreaterThan(Date value) {
            addCriterionForJDBCDate("vistit_time >", value, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitTimeGreaterThanOrEqualTo(Date value) {
            addCriterionForJDBCDate("vistit_time >=", value, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitTimeLessThan(Date value) {
            addCriterionForJDBCDate("vistit_time <", value, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitTimeLessThanOrEqualTo(Date value) {
            addCriterionForJDBCDate("vistit_time <=", value, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitTimeIn(List<Date> values) {
            addCriterionForJDBCDate("vistit_time in", values, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitTimeNotIn(List<Date> values) {
            addCriterionForJDBCDate("vistit_time not in", values, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitTimeBetween(Date value1, Date value2) {
            addCriterionForJDBCDate("vistit_time between", value1, value2, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitTimeNotBetween(Date value1, Date value2) {
            addCriterionForJDBCDate("vistit_time not between", value1, value2, "vistitTime");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeIsNull() {
            addCriterion("vistit_interviewee is null");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeIsNotNull() {
            addCriterion("vistit_interviewee is not null");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeEqualTo(String value) {
            addCriterion("vistit_interviewee =", value, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeNotEqualTo(String value) {
            addCriterion("vistit_interviewee <>", value, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeGreaterThan(String value) {
            addCriterion("vistit_interviewee >", value, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeGreaterThanOrEqualTo(String value) {
            addCriterion("vistit_interviewee >=", value, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeLessThan(String value) {
            addCriterion("vistit_interviewee <", value, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeLessThanOrEqualTo(String value) {
            addCriterion("vistit_interviewee <=", value, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeLike(String value) {
            addCriterion("vistit_interviewee like", value, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeNotLike(String value) {
            addCriterion("vistit_interviewee not like", value, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeIn(List<String> values) {
            addCriterion("vistit_interviewee in", values, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeNotIn(List<String> values) {
            addCriterion("vistit_interviewee not in", values, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeBetween(String value1, String value2) {
            addCriterion("vistit_interviewee between", value1, value2, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitIntervieweeNotBetween(String value1, String value2) {
            addCriterion("vistit_interviewee not between", value1, value2, "vistitInterviewee");
            return (Criteria) this;
        }

        public Criteria andVistitAddrIsNull() {
            addCriterion("vistit_addr is null");
            return (Criteria) this;
        }

        public Criteria andVistitAddrIsNotNull() {
            addCriterion("vistit_addr is not null");
            return (Criteria) this;
        }

        public Criteria andVistitAddrEqualTo(String value) {
            addCriterion("vistit_addr =", value, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrNotEqualTo(String value) {
            addCriterion("vistit_addr <>", value, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrGreaterThan(String value) {
            addCriterion("vistit_addr >", value, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrGreaterThanOrEqualTo(String value) {
            addCriterion("vistit_addr >=", value, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrLessThan(String value) {
            addCriterion("vistit_addr <", value, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrLessThanOrEqualTo(String value) {
            addCriterion("vistit_addr <=", value, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrLike(String value) {
            addCriterion("vistit_addr like", value, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrNotLike(String value) {
            addCriterion("vistit_addr not like", value, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrIn(List<String> values) {
            addCriterion("vistit_addr in", values, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrNotIn(List<String> values) {
            addCriterion("vistit_addr not in", values, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrBetween(String value1, String value2) {
            addCriterion("vistit_addr between", value1, value2, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitAddrNotBetween(String value1, String value2) {
            addCriterion("vistit_addr not between", value1, value2, "vistitAddr");
            return (Criteria) this;
        }

        public Criteria andVistitDetailIsNull() {
            addCriterion("vistit_detail is null");
            return (Criteria) this;
        }

        public Criteria andVistitDetailIsNotNull() {
            addCriterion("vistit_detail is not null");
            return (Criteria) this;
        }

        public Criteria andVistitDetailEqualTo(String value) {
            addCriterion("vistit_detail =", value, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailNotEqualTo(String value) {
            addCriterion("vistit_detail <>", value, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailGreaterThan(String value) {
            addCriterion("vistit_detail >", value, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailGreaterThanOrEqualTo(String value) {
            addCriterion("vistit_detail >=", value, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailLessThan(String value) {
            addCriterion("vistit_detail <", value, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailLessThanOrEqualTo(String value) {
            addCriterion("vistit_detail <=", value, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailLike(String value) {
            addCriterion("vistit_detail like", value, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailNotLike(String value) {
            addCriterion("vistit_detail not like", value, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailIn(List<String> values) {
            addCriterion("vistit_detail in", values, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailNotIn(List<String> values) {
            addCriterion("vistit_detail not in", values, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailBetween(String value1, String value2) {
            addCriterion("vistit_detail between", value1, value2, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVistitDetailNotBetween(String value1, String value2) {
            addCriterion("vistit_detail not between", value1, value2, "vistitDetail");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeIsNull() {
            addCriterion("visit_nexttime is null");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeIsNotNull() {
            addCriterion("visit_nexttime is not null");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeEqualTo(Date value) {
            addCriterionForJDBCDate("visit_nexttime =", value, "visitNexttime");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeNotEqualTo(Date value) {
            addCriterionForJDBCDate("visit_nexttime <>", value, "visitNexttime");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeGreaterThan(Date value) {
            addCriterionForJDBCDate("visit_nexttime >", value, "visitNexttime");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeGreaterThanOrEqualTo(Date value) {
            addCriterionForJDBCDate("visit_nexttime >=", value, "visitNexttime");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeLessThan(Date value) {
            addCriterionForJDBCDate("visit_nexttime <", value, "visitNexttime");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeLessThanOrEqualTo(Date value) {
            addCriterionForJDBCDate("visit_nexttime <=", value, "visitNexttime");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeIn(List<Date> values) {
            addCriterionForJDBCDate("visit_nexttime in", values, "visitNexttime");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeNotIn(List<Date> values) {
            addCriterionForJDBCDate("visit_nexttime not in", values, "visitNexttime");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeBetween(Date value1, Date value2) {
            addCriterionForJDBCDate("visit_nexttime between", value1, value2, "visitNexttime");
            return (Criteria) this;
        }

        public Criteria andVisitNexttimeNotBetween(Date value1, Date value2) {
            addCriterionForJDBCDate("visit_nexttime not between", value1, value2, "visitNexttime");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}